<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Kolektibilitas_pinjaman extends Controller {
	
	function Kolektibilitas_pinjaman()
	{
		parent::Controller();		
	}
	
	function index()
	{
		$this->load->helper('url');
		$this->load->library('id_chart/id_chart');		
		$data['title'] = "Kolektibilitas Pinjaman";		
		$data['main_content'] = 'kolektibilitas_pinjaman';				
		$data['c4'] = $this->id_chart->chart_embed('test4',400,400,site_url('kolektibilitas_pinjaman/example4'),base_url());
		$this->load->view('layout/template', $data);		
	}

	function example4()
	{

		$this->load->helper('url');
		$this->load->library('id_chart/id_chart');
		//for ($i=1;$i<6;$i++){
		//	$data[] = array('label'=>'data '.$i, 'value'=>rand(20,300));
		//}
		$data[] = array('label'=>'Lancar', 'value'=>80);
		$data[] = array('label'=>'Kurang Lancar', 'value'=>10);
		$data[] = array('label'=>'Diragukan', 'value'=>8);
		$data[] = array('label'=>'Macet', 'value'=>2);

		echo $this->id_chart->set_chart('pie')
							->set_data($data)
							//->set_radius(20)
							->render();
	}
}

/* End of file kolektibilitas_pinjaman.php */
/* Location: ./application/controllers/kolektibilitas_pinjaman.php */